<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
	<head>
		<meta charset="utf-8">
		<title></title>
		<link rel="stylesheet" type="text/css" th:href="@{${#httpServletRequest.getContextPath()}+'/css/pub_footer.css'}" />
		<link rel="stylesheet" type="text/css" th:href="@{${#httpServletRequest.getContextPath()}+'/css/pub_head.css'}" />
		<link rel="stylesheet" type="text/css" th:href="@{${#httpServletRequest.getContextPath()}+'/layui/css/layui.css'}" />
		<link rel="stylesheet" type="text/css" th:href="@{${#httpServletRequest.getContextPath()}+'/css/login.css'}" />
	</head>
	<body>
		<div id="head" th:include="../static/publichtml/public_pageHead :: footer1"></div><!-- 头部导入 -->
		<div class="layui-container">
			<div id="top" class="layui-row ">
				<div class="layui-col-xs6 layui-col-sm6 layui-col-md6">
					<!-- top的div下分两份， -->
					<div class="layui-row">
						<!-- 再分一半 -->
						<div class="layui-col-xs6 layui-col-sm6 layui-col-md6">
						</div>
						<div class="layui-col-xs6 layui-col-sm6 layui-col-md6">
							<a th:href="@{${#httpServletRequest.getContextPath()}+'/jump/index'}"><img src="../images/login/4da3aa8a72600bf007b857fd56b73a7ebf4aa766.jpeg" /></a>
						</div>
					</div>
				</div>
				<div class="layui-col-xs6 layui-col-sm6 layui-col-md6">
					<div class="layui-row">
						<div class="layui-col-xs6 layui-col-sm6 layui-col-md6">
						</div>
						<div class=" layui-col-xs6 layui-col-sm6 layui-col-md6 layui-col-md-offset6">
							<div class="father ">
								<i id="i_img"></i>
								<div class="service  inline">
									<span>客服热线</span>
									<p>400-600-0716</p>
								</div>
							</div>
						</div>
					</div> 
				</div>
			</div>
					</div>
				</div>
				<div id="mid">
					<div class="login_bg">
						<div class="login_box shadow">
							<div id="login-input">
								<form id="userInfo" method="post">
									<div class="box_head">
										<h3>会员注册</h3>
									</div>
									<div class="box_mid ">
										<div class="login_title ">
											<label><a href="#">账号登录</a></label>
											<label><a href="#">扫码登录</a></label>
										</div>
										<div class="login_input ">
											<label>用户名&nbsp;&nbsp;&nbsp;：</label>
											<input type="text" name="userId" required lay-verify="required" class="layui-input widths">
										</div>
										<div class="login_input ">
											<label>密&nbsp;&nbsp;&nbsp;码&nbsp;&nbsp;&nbsp;：</label>
											<input type="password" required lay-verify="required" name="password" class="layui-input widths">
										</div>
										<div class="login_box_remember">
											<input type="checkbox" id="reb" name="remember" /><label>&nbsp;&nbsp;下次自动登录</label>
											<span><a href="#">忘记密码?</a></span>
										</div>
										<div class="login_box_submit">
											<span id="submita" class="layui-btn layui-btn-danger">立即登录</span>
										</div>
										<div class="register_contex ">
											<span><a href="/public/register">没有账号？立即注册</a></span>
										</div>
									</div>
									<div class="box_footer ">
										<div>第三方登录</div>
										<div class="other-login wechat-btn wachet_btn2"></div>
										<a href="https://www.jzhfz.com/member/qqLogin">
											<div class="other-login qq_btn"></div>
										</a>
									</div>
								</form>
							</div>
							<div id="login-wechat" class="hidden">
								<div class="box_head">
						 			<h3>会员登录</h3>
								</div>
								<div class="box_mid ">
									<div class="login_title ">
										<label id="wechat_lab">微信登录方便快捷，更省时省力！</label>
									</div>
									<div class="text-center  wechat_img">
										<img style="padding-bottom:20px ;" src="../images/login/wechat.png" />
										<div class="text-center ">
											<h3>扫描二维码登录</h3>
											<p style="font-size: 16px;">请使用<span style="color:#67C23A">手机微信</span>扫码完成登录</p>
										</div>
									</div>
								</div>
								<div class="wechat_back ">
									<div>电脑登录：</div>
									<div class="img_back">
										<img src="../images/login/pcLogin_icon.png" />
									</div>
								</div>
							</div>
						</div>
					</div>
					<div id="bom"></div>
					<div id="footer"></div>
					<script src="../js/jquery-3.6.0.js"></script>
					<script>
						$(function(){
							//$("#head").load("../publichtml/public_pageHead.html");
							$("#footer").load("../publichtml/pub_footer.html");
							$(".wechat-btn").click(function(){
								$("#login-input").toggleClass("hidden");
								$("#login-wechat").toggleClass("hidden");
							})
							$(".img_back>img").click(function(){
								$("#login-input").toggleClass("hidden");
								$("#login-wechat").toggleClass("hidden");
							})
							$("#submita").click(function(){
								$.ajax({
									url:"/backer/login",
									type:"post",
									data:$("#userInfo").serialize(),
									success:function(data){
										if (data === ""){
											alert("用户名或密码错误")
										}else{
											alert("登录成功！")
											location.href = "/backer/user";
										}
									}
								});

							});
						});
					</script>
	</body>
</html>
